<%= error_messages_for :user %>

<p><label for="user_login">Käyttäjätunnus</label><br/>
<%= text_field 'user', 'login' %></p>

<p><label for="user_email">Sähköposti</label><br/>
<%= text_field 'user', 'email' %></p>

<p><label for="user_password">Salasana</label><br/>
<%= password_field 'user', 'password' %></p>

<p><label for="user_password_confirmation">Salsanan vahvistus</label><br/>
<%= password_field 'user', 'password_confirmation' %></p>

<p><label for="user_employee">Henkilö</label><br/>
<%=collection_select 'user', 'employee_id', Employee.find(:all, :order => "last_name, first_name"), :id, :full_name, :include_blank => true %></p>

<% for role in @roles %>
<div>
	<%= check_box_tag "user[role_ids][]", role.id, @user.roles.include?(role) %> <%= h role.name %>
</div>
<% end %>